package mqpaydemo.paydemo.controller;

import mqpaydemo.paydemo.mq.ConfirmSend;
import mqpaydemo.paydemo.mq.Send;
import org.springframework.web.bind.annotation.PostMapping;
import org.springframework.web.bind.annotation.RestController;

import javax.annotation.Resource;

/**
 * @Description:
 * @Author: liujinsheng
 * @Date: 2021/9/10.
 */
@RestController
public class TestMqController {
    @Resource
    Send send;
    @Resource
    ConfirmSend confirmSend;
    @PostMapping("/testMq")
    public String send(){
        send.send();
        return "发送成功";
    }
    @PostMapping("/comfirm")
    public String  comfirm(){
        confirmSend.confirmSend();
        return "发送确认消息";
    }

}
